package com.hsy.crm.web.web.system;

import com.hsy.crm.web.domain.cm.Response;
import com.hsy.crm.web.domain.vo.dict.DictPageVo;
import com.hsy.crm.web.domain.vo.dict.DictUpdateVo;
import com.hsy.crm.web.service.impl.DictService;
import com.hsy.crm.web.web.BaseAction;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 字典
 */
@RestController
@RequestMapping("/dict")
public class DictAction  extends BaseAction {

    @Autowired
    DictService dictService;

    @RequestMapping("/page")
    public String page(DictPageVo dictPageVo) {
        return Response.body(dictService.page(dictPageVo));
    }

    @RequestMapping("/update")
    public String update(DictUpdateVo dictUpdateVo){
        return Response.body(dictService.updateDicts(dictUpdateVo));
    }



}
